package com.zygh.policeasset.service;

import com.github.pagehelper.PageHelper;
import com.github.pagehelper.PageInfo;
import com.zygh.policeasset.mapper.AssetsApprovalStepsMapper;
import com.zygh.policeasset.pojo.AssetsApprovalSteps;
import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
/* loaded from: police-asset-2.0-0.0.1-SNAPSHOT.jar:BOOT-INF/classes/com/zygh/policeasset/service/AssetsApprovalStepsService.class */
public class AssetsApprovalStepsService {
    @Autowired
    AssetsApprovalStepsMapper assetsApprovalStepsMapper;

    public int deleteByStepType(String stepType) {
        return this.assetsApprovalStepsMapper.deleteByStepType(stepType);
    }

    public int insert(AssetsApprovalSteps assetsApprovalSteps) {
        return this.assetsApprovalStepsMapper.add(assetsApprovalSteps);
    }

    public AssetsApprovalSteps findById(Integer id) {
        return this.assetsApprovalStepsMapper.findById(id);
    }

    public List<AssetsApprovalSteps> findAll() {
        return this.assetsApprovalStepsMapper.findAll();
    }

    public int updateById(AssetsApprovalSteps assetsApprovalSteps) {
        return this.assetsApprovalStepsMapper.updateById(assetsApprovalSteps);
    }

    public PageInfo findByCondition(String stepsType, int pageNum, int pageSize) {
        PageHelper.startPage(pageNum, pageSize);
        return new PageInfo<>(this.assetsApprovalStepsMapper.findByCondition(stepsType));
    }

    public List<AssetsApprovalSteps> findByStepsType(String stepsType) {
        return this.assetsApprovalStepsMapper.findByCondition(stepsType);
    }
}